.class public Lrexsee/natives/widget/CustomizedGallery;
.super Landroid/widget/Gallery;
.source "CustomizedGallery.java"


# annotations
.annotation system Ldalvik/annotation/MemberClasses;
    value = {
        Lrexsee/natives/widget/CustomizedGallery$OnTransformListener;
    }
.end annotation


# instance fields
.field private mListener:Lrexsee/natives/widget/CustomizedGallery$OnTransformListener;


# direct methods
.method public constructor <init>(Landroid/content/Context;)V
    .locals 1
    .param p1, "context"    # Landroid/content/Context;

    .prologue
    .line 17
    invoke-direct {p0, p1}, Landroid/widget/Gallery;-><init>(Landroid/content/Context;)V

    .line 14
    const/4 v0, 0x0

    iput-object v0, p0, Lrexsee/natives/widget/CustomizedGallery;->mListener:Lrexsee/natives/widget/CustomizedGallery$OnTransformListener;

    .line 18
    const/4 v0, 0x1

    invoke-virtual {p0, v0}, Lrexsee/natives/widget/CustomizedGallery;->setStaticTransformationsEnabled(Z)V

    .line 19
    invoke-virtual {p0}, Lrexsee/natives/widget/CustomizedGallery;->setDefaultTransformListener()V

    .line 20
    return-void
.end method


# virtual methods
.method protected getChildStaticTransformation(Landroid/view/View;Landroid/view/animation/Transformation;)Z
    .locals 5
    .param p1, "child"    # Landroid/view/View;
    .param p2, "t"    # Landroid/view/animation/Transformation;

    .prologue
    .line 24
    invoke-virtual {p2}, Landroid/view/animation/Transformation;->clear()V

    .line 25
    sget v3, Landroid/view/animation/Transformation;->TYPE_MATRIX:I

    invoke-virtual {p2, v3}, Landroid/view/animation/Transformation;->setTransformationType(I)V

    .line 26
    iget-object v3, p0, Lrexsee/natives/widget/CustomizedGallery;->mListener:Lrexsee/natives/widget/CustomizedGallery$OnTransformListener;

    if-eqz v3, :cond_0

    .line 27
    invoke-virtual {p0}, Lrexsee/natives/widget/CustomizedGallery;->getWidth()I

    move-result v3

    invoke-virtual {p0}, Lrexsee/natives/widget/CustomizedGallery;->getPaddingLeft()I

    move-result v4

    sub-int/2addr v3, v4

    invoke-virtual {p0}, Lrexsee/natives/widget/CustomizedGallery;->getPaddingRight()I

    move-result v4

    sub-int/2addr v3, v4

    div-int/lit8 v3, v3, 0x2

    invoke-virtual {p0}, Lrexsee/natives/widget/CustomizedGallery;->getPaddingLeft()I

    move-result v4

    add-int v0, v3, v4

    .line 28
    .local v0, "center":I
    invoke-virtual {p1}, Landroid/view/View;->getLeft()I

    move-result v3

    invoke-virtual {p1}, Landroid/view/View;->getWidth()I

    move-result v4

    div-int/lit8 v4, v4, 0x2

    add-int v1, v3, v4

    .line 29
    .local v1, "childCenter":I
    sub-int v3, v0, v1

    int-to-float v3, v3

    invoke-virtual {p1}, Landroid/view/View;->getWidth()I

    move-result v4

    int-to-float v4, v4

    div-float v2, v3, v4

    .line 30
    .local v2, "position":F
    iget-object v3, p0, Lrexsee/natives/widget/CustomizedGallery;->mListener:Lrexsee/natives/widget/CustomizedGallery$OnTransformListener;

    invoke-virtual {v3, p1, p2, v2}, Lrexsee/natives/widget/CustomizedGallery$OnTransformListener;->run(Landroid/view/View;Landroid/view/animation/Transformation;F)Z

    move-result v3

    .line 31
    .end local v0    # "center":I
    .end local v1    # "childCenter":I
    .end local v2    # "position":F
    :goto_0
    return v3

    :cond_0
    const/4 v3, 0x0

    goto :goto_0
.end method

.method public setDefaultTransformListener()V
    .locals 1

    .prologue
    .line 38
    new-instance v0, Lrexsee/natives/widget/CustomizedGallery$1;

    invoke-direct {v0, p0}, Lrexsee/natives/widget/CustomizedGallery$1;-><init>(Lrexsee/natives/widget/CustomizedGallery;)V

    .line 83
    .local v0, "transformListener":Lrexsee/natives/widget/CustomizedGallery$OnTransformListener;
    invoke-virtual {p0, v0}, Lrexsee/natives/widget/CustomizedGallery;->setTransformListener(Lrexsee/natives/widget/CustomizedGallery$OnTransformListener;)V

    .line 84
    return-void
.end method

.method public setTransformListener(Lrexsee/natives/widget/CustomizedGallery$OnTransformListener;)V
    .locals 0
    .param p1, "listener"    # Lrexsee/natives/widget/CustomizedGallery$OnTransformListener;

    .prologue
    .line 35
    iput-object p1, p0, Lrexsee/natives/widget/CustomizedGallery;->mListener:Lrexsee/natives/widget/CustomizedGallery$OnTransformListener;

    .line 36
    return-void
.end method
